//
// Created by 王书哲 on 25-3-15.
//
#include <stdio.h>
#include <string.h>
#define M1 "How are ya, sweetie?"

int s_strlen(char *str);
int main(void)
{
    char *ch;
    printf("The length of %s is %d\n", M1, s_strlen(M1));
    ch = "How are ya, sweetie?";
    int len = s_strlen(ch);
    printf("The length of %s is %d\n", ch, len);
    return 0;
}

int s_strlen(char *str)
{
    int i;
    for (i = 0; *str != '\0'; str++)
        i++;
    return i;
}